/**
 * 
 */
package com.kbcss.dto;

import java.sql.Time;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.ManyToMany;
import javax.persistence.OneToMany;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * @author mufa
 *
 */
@Entity
public class Discussion {
	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	private int disId;
	private String disTopic;
	private String disDesc;
	@Temporal(TemporalType.DATE)
	private Date disDate;
	@Temporal(TemporalType.TIME)
	private Time disTime;
	
	@ManyToMany(mappedBy="discuss")
	private Collection<UserDetails> userList=new ArrayList();
	
	@OneToMany(mappedBy="discuss1")
	private Collection<Comments> cmnt=new ArrayList<Comments>();

	public Collection<Comments> getCmnt() {
		return cmnt;
	}

	public void setCmnt(Collection<Comments> cmnt) {
		this.cmnt = cmnt;
	}

	public int getDisId() {
		return disId;
	}

	public void setDisId(int disId) {
		this.disId = disId;
	}

	public String getDisTopic() {
		return disTopic;
	}

	public void setDisTopic(String disTopic) {
		this.disTopic = disTopic;
	}

	public String getDisDesc() {
		return disDesc;
	}

	public void setDisDesc(String disDesc) {
		this.disDesc = disDesc;
	}

	public Date getDisDate() {
		return disDate;
	}

	public void setDisDate(Date disDate) {
		this.disDate = disDate;
	}

	public Time getDisTime() {
		return disTime;
	}

	public void setDisTime(Time disTime) {
		this.disTime = disTime;
	}

	public Collection<UserDetails> getUserList() {
		return userList;
	}

	public void setUserList(Collection<UserDetails> userList) {
		this.userList = userList;
	}
	

}
